In order to find particular information according to a pattern in an email, pattern matching is used. With pattern matching, the categoriser searches for information that follows a particular syntax. This syntax is based on pairs of keys and values and separators, which delimit them.
Under the Email | Pattern matching menu option, the Specifications tab, you are able to define specifications which describe the appearance of values for different keys. The example below shows a specification which describes the value for PersonNummer, the Swedish type of social security number.
The value of the social security number 771122-4499 has the following format: 6-8 digits, an optional separator, and another 4 digits. We want to save the digits, but not the separator. All of this will be described using subspecifications. The social security number example consists of three subspecifications.
To add a subspecification in the Email – pattern matching window, start by doing any of the following under header Subspecification:
For each subspecification, you need to state the subspecification’s type, number of repetitions and whether or not it should be saved to a contact data key.
The following standard types of subspecifications are available:
Subspecification |
Explanation |
---|---|
CapitalLetter |
upper case letters, A to Z |
Character |
any character, e.g. ":" or "@" |
Digit |
numbers, 0 to 9 |
Letter |
all English letters |
LowercaseLetter |
lower case letters, a to z |
You may also use a specific character by entering the desired character as subspecification.
Under Repetition, state the lowest and highest number of times this subspecification is to be repeated.
Mark checkbox Is Saved if the value is to be saved in the contact data key.
When CallGuide Email Server is searching for values matching the description in the specification, the relative order between the subspecifications must be the same.
In the example we have also defined that the subspecification of the type "Separator" will occur once and that it should be excluded from a contact data key.
Note that the PersonNummer, social security number in the example, also could have been entered as 197711224499.
The specification PersonNummer, describes the composition of the value for the pattern matching key PersonNummer. We are now going to add the key itself. To do this, switch to the Pattern tab.
In order for the pattern matching to work, Name must be identical to the string that is to be found in the email text. The Start and End separators specify the characters which delimit the key from its values. In our case, it ought to be ":" and ":" according to the example above.
The values allowed for a key are indicated by Specification. Here we choose our defined specification “PersonNummer”.
Under Contact data key, select the contact data key that is to hold the produced value. We choose "Identification".
Let us briefly look at an example where pattern matching has been used to get values for different contact data keys, which in turn are used to decide which automatic answer to send.
According to the configuration above, emails
Telia CallGuide version 10.1. New info since last release is highlighted. ©Telia Sverige AB